Optical Encoder with Code Wheel Misalignment Detection and Automatic Gain Control

ABSTRACT

According to one embodiment, there is provided a device and method for correcting code wheel misalignment which employs upper and lower code wheel misalignment photodetectors positioned above and below at least first and second motion detection photodetectors. According to other embodiments, there are provided a device and method for automatically setting the gain of an output circuit in an optical encoder. Still further embodiments of optical encoders combine the code wheel misalignment and automatic gain control features of the invention.

CROSS REFERENCE TO RELATED APPLICATION

This application is a divisional application, which is based on, andclaims priority to, U.S. Pat. No. 7,709,784 (Utility patent applicationSer. No. 12/112,962) filed on Apr. 30, 2008 entitled “Optical Encoderwith Code Wheel Misalignment Correction and Automatic Gain Control” toThor et al, and which is incorporated herein by reference in itsentirety.

RELATED APPLICATION

This application incorporates by reference, in its entirety, U.S. Pat.No. 7,732,754 (Utility patent application Ser. No. 12/112,867) filedApr. 30, 2008 entitled “Optical Encoder with Amplitude Correction” toToh et al.

FIELD OF THE INVENTION

Various embodiments of the invention described herein relate to thefield of optical encoders, and components, devices, systems and methodsassociated therewith.

BACKGROUND

Most motion detection or position optical encoders of the prior artcomprise four photodiode channels, typically labelled namely A, A/, Band B/, respectively. Such optical encoders work by generatingphotocurrent using these channels, and are usually spatially arranged inthe encoder such that they are 90 degrees out of phase apart withrespect to one another. It is imperative that the code wheel of theencoder and the photodiodes be aligned properly and accurately inrespect of one another. Otherwise, inaccuracies and errors result in thephotocurrents produced by such channels, which lead to inaccurateposition or motion information being generated by the encoder.Currently, no method or device exists to detect code wheel misalignmentusing photodiodes incorporated into an encoder integrated circuit (or“IC”).

In addition, most motion detection or position optical encoders of theprior art are designed and fabricated using well known bipolarprocesses, which enable photocurrent contrast to be obtained using thelog-antilog architecture inherent in most BJT devices. However, with theadvent of CMOS processes, encoder designs are being adapted to MOSdevices for better scalability, lower cost and lower power. CMOSprocesses, however, are typically not amenable to the log-antilogarchitecture often employed in bipolar devices. As a result, morestraightforward and conventional transimpedance amplification circuitrymust be employed in CMOS processes. But to amplify photocurrents toreasonable voltage output levels, a resistor of the correct value mustbe used, which is a difficult proposition to implement in CMOS devicesemploying conventional transimpedance amplification circuits.

What is needed is a device and method for detecting code wheelmisalignment using photodiodes incorporated, for example, into anencoder IC. What is also needed is a device and method for setting thegain of a transimpedance amplifier automatically, which depends on theinput light power and the photocurrent generated.

SUMMARY

In some embodiments, there is provided an optical encoder comprising alight emitter configured to emit a collimated beam of light, a codewheel having a plurality of apertures disposed therethrough andconfigured to rotate substantially in a plane and in a first direction,a light detector comprising at least first and second photodetectorspositioned along the first direction on a first vertical portion thereofand at least upper and lower code wheel misalignment photodetectorspositioned on second and third vertical portions thereof disposed,respectively, above and below the first and second photodetectors, and acode wheel misalignment circuit, where the light detector faces thelight emitter, the code wheel is disposed and configured to rotatebetween the light emitter and the light detector such that thecollimated light beam is directed substantially in the plane through theapertures onto the first, second and third vertical portions as thewheel rotates, the first and second photodetectors are configured togenerate, in response to first portions of the collimated beam beingincident thereon, first and second output signals, and the upper andlower code wheel misalignment photodetectors are configured to generate,in response to second and third portions of the collimated beam beingincident thereon, third and fourth output signals provided to the codewheel misalignment circuit, the circuit being configured to detect adifference between the amplitudes of the third and fourth outputsignals, the circuit generating an error signal indicative of a codewheel misalignment when the difference exceeds a predeterminedthreshold.

In another embodiment, there is provided a method of generating an errorsignal indicative of code wheel misalignment in an optical encodercomprising providing a light emitter configured to emit a collimatedbeam of light, providing a code wheel having a plurality of aperturesdisposed therethrough and configured to rotate substantially in a planeand in a first direction, providing a light detector comprising at leastfirst and second photodetectors positioned along the first direction ona first vertical portion thereof and at least upper and lower code wheelmisalignment photodetectors positioned on second and third verticalportions thereof disposed, respectively, above and below the first andsecond photodetectors, and providing a code wheel misalignment circuit,rotating the code wheel between the light emitter and the light detectorsuch that the collimated light beam is directed substantially in theplane through the apertures onto the first, second and third verticalportions, generating with the first and second photodetectors,respectively, first and second output signals in response to firstportions of the collimated beam being incident thereon, generating withthe upper and lower code wheel misalignment photodetectors,respectively, third and fourth output signals in response to second andthird portions of the collimated beam being incident thereon, anddetecting a difference in amplitudes of the third and fourth outputsignals that exceeds a predetermined threshold and is indicative of amisalignment of the code wheel.

In a further embodiment, there is provided an optical encoder comprisinga light emitter configured to emit a collimated beam of light, a codewheel having a plurality of apertures disposed therethrough andconfigured to rotate substantially in a plane and in a first direction,a light detector comprising at least first and second photodetectorspositioned along the first direction on a first vertical portion thereofand at least a first automatic gain control photodetector positioned ona second vertical portion thereof, the second vertical portion beingvertically offset from the first vertical portion, and an automatic gaincontrol circuit comprising a comparator and a decoder, where the lightdetector faces the light emitter, the code wheel is disposed andconfigured to rotate between the light-emitting element and the lightdetector such that the collimated light beam is directed substantiallyin the plane through the apertures onto the first and second verticalportions as the wheel rotates, the first and second photodetectors areconfigured to generate, in response to first portions of the collimatedbeam being incident thereon, first and second output signals, and thefirst automatic gain control photodetector is configured to generate, inresponse to the second portion of the collimated beam being incidentthereon, a third output signal provided to the circuit, the circuitbeing configured to receive the third output signal and compare same toa reference voltage using the comparator, an output of the comparatorbeing provided to a decoder which sets the gain of the automatic gaincircuit according to the comparator output.

In yet a further embodiment, there is provided a method of providingautomatic gain control in an optical encoder comprising providing alight emitter configured to emit a collimated beam of light, providing acode wheel having a plurality of apertures disposed therethrough andconfigured to rotate substantially in a plane and in a first direction,providing a light detector comprising at least first and secondphotodetectors positioned along the first direction on a first verticalportion thereof and at least a first automatic gain controlphotodetector positioned on a second vertical portion thereof, thesecond vertical portion being vertically offset from the first verticalportion, and providing an automatic gain control circuit comprising acomparator and a decoder, rotating the code wheel between thelight-emitting element and the light detector such that the collimatedlight beam is directed substantially in the plane through the aperturesonto the first and second vertical portions, generating with the firstand second photodetectors, in response to first portions of thecollimated beam being incident thereon, first and second output signals,generating with the first automatic gain control photodetector, inresponse to the second portion of the collimated beam being incidentthereon, a third output signal and providing same to the circuit,comparing the third output signal and a reference voltage in thecomparator and generating an output from the comparator on the basis ofsuch comparison, and providing the comparator output to a decoder andsetting the gain of the automatic gain circuit according to thecomparator output.

Further embodiments are disclosed herein or will become apparent tothose skilled in the art after having read and understood thespecification and drawings hereof.

BRIEF DESCRIPTION OF THE DRAWINGS

Different aspects of the various embodiments of the invention willbecome apparent from the following specification, drawings and claims inwhich:

FIG. 1A shows one embodiment of a light detector 40 of the inventionhaving code wheel misalignment detection capabilities;

FIG. 1B shows a cross-sectional view of light detector 40 of FIG. 1A,together with a light emitter 5 and a code wheel 20, wherein code wheel20 is properly aligned with respect to light detector 40;

FIG. 1C shows a modified view of FIG. 1B, wherein code wheel 20 ismisaligned with respect to light detector 40, thereby preventing lightfrom being incident upon upper code wheel misalignment photodetector 90a;

FIG. 2 shows one embodiment of a circuit 120 of the inventioncorresponding to the light detector 40 of FIG. 1;

FIG. 3 shows one embodiment of a light detector 40 of the inventionhaving a single automatic gain control photodetector 90 a;

FIG. 4 shows one embodiment of a light detector 40 of the inventionhaving dual automatic gain control photodetectors 90 a and 90 b;

FIG. 5 shows one embodiment of a light detector 40 of the inventionhaving triple automatic gain control photodetectors 90 a, 90 b and 90 c,and

FIG. 6 shows a block diagram according to one embodiment of circuit 130of the invention.

The drawings are not necessarily to scale. Like numbers refer to likeparts or steps throughout the drawings, unless otherwise noted.

DETAILED DESCRIPTIONS OF SOME PREFERRED EMBODIMENTS

According to various embodiments, there are provided a device and methodfor correcting code wheel misalignment which employs upper and lowercode wheel misalignment photodetectors positioned above and below atleast first and second motion detection photodetectors. According toother embodiments, there are provided a device and method forautomatically setting the gain of an output circuit in an opticalencoder. Still further embodiments combine the code wheel misalignmentand automatic gain control features of the invention in an opticalencoder.

According to one embodiment shown in FIGS. 1A, 1B and 1C, there isprovided an optical encoder comprising a light emitter 5 configured toemit a collimated beam of light 15; a code wheel 20 having a pluralityof apertures (e.g. 21) disposed therethrough and configured to rotatesubstantially in a plane 16 and in a first direction 110; and a lightdetector 40 comprising at least first and second photodetectors 41 a (A)and 43 a (B) positioned along first direction 110 on a first verticalportion 70 thereof. At least upper and lower code wheel misalignmentphotodetectors 90 a and 90 b are positioned on second and third verticalportions 80 and 85 disposed, respectively, above and below first andsecond motion detection photodetectors 41 a and 43 a. The light detector40 faces the light emitter, and the code wheel is disposed andconfigured to rotate between the light emitter and the light detectorsuch that the collimated light beam is directed through the aperturesonto the first, second and third vertical portions 70, 80 and 85,respectively. As the code wheel rotates, first and second photodetectors41 a and 43 a are configured to generate, in response to illuminationarea 50 a of the collimated beam, first and second output signals. Upperand lower code wheel misalignment photodetectors 90 a and 90 b areconfigured to generate, in response to respective portions of thecollimated beam being incident thereon, third and fourth output signals,which are provided to a code wheel misalignment circuit (120 of FIG. 2).The circuit 120 is configured to detect a difference between theamplitudes of the third and fourth output signals, and generate an errorsignal indicative of code wheel misalignment when the difference exceedsa predetermined threshold.

Continuing to refer to FIGS. 1A, 1B and 1C, note that additional motiondetection photodetectors such as photodetectors 41 b (A/), 43 b (B/), 42a (A), 44 a (B) and 42 b (A/) may also be included in photodetector 40.

In a preferred embodiment of the invention, the surface areas of upperand lower code wheel misalignment photodetectors 90 a and 90 b are equalor substantially equal. If the surface areas corresponding to upper andlower code wheel misalignment photodetectors 90 a and 90 b are equal orsubstantially equal, and these substantially equal surface areas areexposed to substantially equal amounts of incident light (as shown inFIG. 1B, where code wheel 20 is properly aligned with respect to lightdetector 40) then the photocurrents (third and fourth output signals)delivered by photodetectors 90 a and 90 b will also be the same. On theother hand, if these substantially equal surface areas are exposed tounequal amounts of incident light (as shown in FIG. 1C, where code wheel20 is misaligned with respect to light detector 40 thereby blockinglight from being incident on upper photodetector 90 a), then thephotocurrents (third and fourth output signals) delivered by the twophotodetectors 90 a and 90 b will not be equal to each other.

The photocurrents delivered by the two photodetectors 90 a and 90 b arepreferably converted into voltage signals using transimpedanceamplifiers 122 a and 122 b (shown in FIG. 2), since voltage comparisonsmay be carried out more easily in devices made according to conventionalCMOS processes. The output voltages from these two code wheelmisalignment channels may then be compared using a comparator 124 (shownin FIG. 2) having a hysteresis value with a set margin. When thedifference between the two signals delivered by the code wheelmisalignment channels exceeds the margin (as a result of code wheelmisalignment, such as shown in FIG. 1C), an error signal is generatedthat is indicative of the code wheel and photodiode channels beingmisaligned in respect of the vertical direction or y-axis. Note thatmore than two photodetectors 90 a and 90 b may be employed to detectcode wheel misalignment.

FIG. 2 shows a block diagram according to one embodiment of circuit 120adapted to receive and process output signals generated by upper andlower code wheel misalignment photodetectors 90 a and 90 b. As shown,circuit 120 comprises upper and lower code wheel misalignmentphotodetectors 90 a and 90 b, transimpedance amplifiers 122 a and 122 boperably connected to photodetectors 90 a and 90 b, and comparator 124configured to provide an output error signal indicative of code wheelmisalignment when the differences between the signals provided byamplifiers 122 a and 122 b to comparator 124 exceed a predeterminedthreshold. To compensate for minor differences in the amplitudes of theoutput signals provided by photodetectors 90 a and 90 b that arise fromsuch influences as amplifier offsets, device imperfections, dust or inkmist, the hysteresis of comparator 124 may be designed into comparator124, or may be adjusted or set during operation. The value of thehysteresis should be small and in the range of tens of millivolts toabout 100 mV. When the difference in amplitudes provided by amplifiers122 a and 122 b exceeds such a value, the error signal should begenerated.

In another embodiment, and as illustrated in FIGS. 3 through 6, thereare provided devices and methods for implementing automatic gain control(AGC) in an optical encoder, where an average light input is measured.Three different embodiments of such devices and methods are illustratedherein, wherein at least one extra or additional automatic gain controlphotodiode is employed in light detector 40 to sense average light inputand thereby average out the photocurrent measured through one or moreapertures in a code wheel.

FIG. 3 shows a first such device containing a single automatic gaincontrol photodiode 90 b, where automatic gain control photodiode 90 b isplaced beneath and vertically offset from motion detection photodiodes41 a (A), 43 a (B), 41 b (A/), 43 b (B/), 42 a (A), 44 a (B) and 42 b(A/). FIG. 4 depicts a second such device, where automatic gain controlphotodiodes 90 a and 90 b are placed beneath and vertically offset frommotion detection photodiodes 41 a (A), 43 a (B), 41 b (A/), 43 b (B/),42 a (A), 44 a (B) and 42 b (A/). FIG. 5 illustrates a third suchdevice, where automatic gain control photodiodes 90 a and 90 b areplaced beneath and vertically offset from first row of motion detectionphotodiodes 41 a (A), 43 a (B), 41 b (A/), 43 b (B/), 42 a (A), 44 a (B)and 42 b (A/), and second row of motion detection photodiodes 41 a′ (A),43 a′ (B), 41 b′ (A/), 43 b′ (B/), 42 a′ (A), 44 a′ (B) and 42 b′ (A/),and automatic gain control photodiode 90 c is placed between such firstand second rows of motion detection photodiodes. Those skilled in theart will understand that many other permutations, combinations andconfigurations of automatic gain control photodiodes and motion controlphotodiodes may also be employed and nevertheless fall within the scopeof the invention. The greater the number of automatic gain controlphotodiodes employed, the increased sensitivity light detector 40 willfeature and the less sensitivity there will be from light sourcevariation or photodiode contamination.

FIG. 6 shows one embodiment of a block diagram of an automatic gaincontrol circuit 130 in an optical encoder using the above-describedautomatic gain control photodiodes. Circuit 130 comprises automatic gaincontrol photodiode 90, transimpedance amplifiers 132 a, 134 a and 142 a,low pass filter 144, comparator 146, decoder 148 and variable resistorsassociated with each of transimpedance amplifiers 132 a, 134 a and 142a. Referring additionally to FIGS. 3 through 5, it will be seen that thespatial positions of automatic gain control photodiodes 90 a, 90 b and90 c in light detectors 40 yield average photocurrents output therefromthat vary little over time owing to such photodiodes having fixedsurface areas exposed to light beam portion 50 a. The relativelyconstant photocurrents generated by automatic gain control photodiodes90 a, 90 b and 90 c are inputs to comparator 146, and are comparedagainst desired reference voltage V_(ref). The result of such comparisonis passed to decoder 148, which then determines the level of gain toapply. In such a feedback system, the gain of circuit 130 is adjusteduntil the output signal V_(out) is substantially the same as the desiredreference voltage V_(ref).

Continuing to refer to FIG. 6, transimpedance amplifier 142 a convertsthe photocurrent(s) delivered by automatic gain control photodiodes 90a, 90 b and/or 90 c into a voltage signal V_(out), which is passed tolow pass filter 144 to filter out undesired AC components. The remainingfiltered signal (V_(out) _(—) I_(pf)) represents an average DC value ofthe photocurrent measured by automatic gain control photodiodes 90 a, 90b and/or 90 c multiplied by a factor set by the feedback resistor.V_(out) _(—) I_(pf) is compared against reference voltage desiredV_(ref), which is set according to the particular application andmanufacturing process at hand. The output of comparator 146 is sent todecoder 148, which determines the gain to use in adjusting V_(out) _(—)I_(pf) to be as close as possible to V_(ref). The same gain is appliedto each of channels A, B, A/ and B/ so that the output voltages providedby these channels match those of V_(ref).

To make optimal use of this invention, there should be a known andestablished relationship between the photocurrents delivered by channelsA, B, A/and B/ on the one hand, and those delivered by automatic gaincontrol photodiodes 90 a, 90 b and/or 90 c on the other hand. As alludedto above, automatic gain control photodiodes 90 a, 90 b and/or 90 cmeasure an average current corresponding essentially to all the motiondetection photodiode channels, which receive fluctuating amounts oflight as light beam portion 50 a scans thereover. For example, if thephotocurrent from Channel A is designed to have 5 times the photocurrentdelivered by automatic gain control photodiode 90 a, then the feedbackgain of Channel A will be one fifth the gain applied to automatic gaincontrol photodiode 90 a. Assuming all motion detection channels have thesame surface areas exposed to light beam portion 50 a and the sameresponsiveness, then such a method will ensure that the voltage swingsof all the motion detection photodiode channels stay at a desiredreference voltage using only a single additional automatic gain controlphotodiode 90 a.

Note that according to one embodiment only one automatic gain controlphotodiode 90 a, 90 b or 90 c is required to provide automatic gaincontrol correction and feedback. Note further that only one pair ofmotion detection photodiodes 41 a and 41 b is required in opticalencoder 10 of the invention. The use of additional reference and motiondetection photodetectors or photodiodes in light detector 40 adds to theaccuracy and efficacy of optical encoder 10 of the invention however.

It will now become apparent to those skilled in the art that the variousembodiments of the invention disclosed herein provide severaladvantages, including, but not limited to providing optical encodershaving enhanced ability to detect code wheel misalignment and improvedautomatic gain control of the output signals provided by an opticalencoder. Those skilled in the art will also appreciate that variousembodiments of the invention are efficacious in detecting misalignmentof a code wheel and providing position information of increased accuracyfrom an optical encoder or optical encoder incorporated into an IC.

Moreover, the various embodiments of the invention are amenable and welladapted for use in standard CMOS manufacturing processes, are simple andeasy to implement, determine whether a code wheel is misaligned inrespect of motion detection photodiodes, regulate output voltage swingsresulting from photodiode input currents, provide a position sensingmethod which remains robust despite varying emitter/detector distances,provide a position sensing method which is fairly insensitive to outputvoltage degradation and part-to-part variation, provide a positionsensing method which minimizes variations between parts and inphotodiode current, can regulate signal levels over wide ranges, areessentially independent of motion detector photodiode signal variation,and solve problems arising from the presence of contaminants such asdust, ink mist, and the like.

Note that the terms “vertical” and “horizontal” employed herein areintended to refer to the relative orientations of light detector 40 andthe various photodiodes arranged thereon as they relate spatially to oneanother and to the code wheel and light emitter. Note further thatvarious types of photodetectors known in the art may be employed in theinvention, in addition to photodiodes.

Note further that included within the scope of the present invention aremethods of making and having made the various components, devices andsystems described herein.

The above-described embodiments should be considered as examples of thepresent invention, rather than as limiting the scope of the invention.In addition to the foregoing embodiments of the invention, review of thedetailed description and accompanying drawings will show that there areother embodiments of the invention. Accordingly, many combinations,permutations, variations and modifications of the foregoing embodimentsof the invention not set forth explicitly herein will nevertheless fallwithin the scope of the invention.

1-21. (canceled)
 22. A method of providing automatic gain control in anoptical encoder, comprising: providing a light emitter configured toemit a collimated beam of light; providing a code wheel having aplurality of apertures disposed therethrough and configured to rotatesubstantially in a plane and in a first direction; providing a lightdetector comprising at least first and second photodetectors positionedalong the first direction on a first vertical portion thereof and atleast a first automatic gain control photodetector positioned on asecond vertical portion thereof, the second vertical portion beingvertically offset from the first vertical portion; providing anautomatic gain control circuit comprising a comparator and a decoder;rotating the code wheel between the light-emitting element and the lightdetector such that the collimated light beam is directed substantiallyin the plane through the apertures onto the first and second verticalportions; generating with the first and second photodetectors, inresponse to first portions of the collimated beam being incidentthereon, first and second output signals; generating with the firstautomatic gain control photodetector, in response to the second portionof the collimated beam being incident thereon, a third output signal andproviding same to the circuit; comparing the third output signal and areference voltage in the comparator and generating an output from thecomparator on the basis of such comparison, and providing the comparatoroutput to a decoder and setting the gain of the automatic gain circuitaccording to the comparator output.
 23. The method of claim 22, furthercomprising providing a second automatic gain control photodetectorpositioned on a third vertical portion of the light detector verticallyoffset from the first and second vertical portions and configured togenerate, in response to the third portion of the collimated beam beingincident thereon, a fourth output signal.
 24. The method of claim 23,further comprising providing the fourth output to the circuit andcomparing same to the reference voltage using the comparator.
 25. Themethod of claim 22, further comprising providing a third automatic gaincontrol photodetector positioned on a fourth vertical portion of thelight detector vertically offset from the first, second and thirdvertical portions and configured to generate, in response to the fourthportion of the collimated beam being incident thereon, a fifth outputsignal.
 26. The method of claim 25, further comprising providing thefifth output to the circuit and comparing same to the reference voltageusing the comparator.